import { useState } from 'react';

import { CodeContext, CodeResultContext } from './context/CodeContext';

import App from './App';
function AppWrapper() {
	const [code, setCode] = useState('');
	const [result, setResult] = useState('');
	return (
		<div>
			<CodeContext.Provider value={{ code, setCode }}>
				<CodeResultContext.Provider value={{ result, setResult }}>
					<App />
				</CodeResultContext.Provider>
			</CodeContext.Provider>
		</div>
	);
}

export default AppWrapper;
